<extend name="Base/common"/>
<block name="body">
<style type="text/css">
  #MyCare .tag .checked {
    background: none;

    color: #4ea3fd !important;
    border-bottom:2px solid #4ea3fd;
}

#MyCare .tag {
    text-align: center;
    padding: 0px;
    background-color: #fff;

}

#MyCare .tag span {
    border: none; 
    color: gray;
    padding: 8px;
    border-radius: 5px;
}.con_empty{	font-size:50px;	color:#E7E6E6;	width:100%;	text-align:center;	font-weight: bold;	line-height:90px;	}.marg{	margin-top:50px;}
</style>
		<!--首页-->
		<div id="MyCare">
			<header>
				<a href="{:U('Index/index')}" class="back"><img src="__IMG__/images/back_03.png"/></a>
				我的收藏
				<a href="javascript:;" class="sure">编辑</a>
			</header>
			<div class="tag">
				<a href="__ACTION__/teaching/2" style="display: block;width:50%; float:left;border-right:1px solid #EFEEEE;height:70px;">
				  <span style="display: block;width:100%;color:#333;height:70px; font-size:34px; line-height: 53px;" <eq name="Think.get.teaching" value="2">class="checked"</eq>>老师</span>
				</a>

				<a href="__ACTION__/teaching/1" style="display: block;width:50%; float:right;">
				  <span style="display: block;width:100%;color:#333;height:70px; font-size:34px; line-height: 53px;" <eq name="Think.get.teaching" value="1">class="checked"</eq>>学生</span>
				</a>
				<div style="clear:both;"></div>
			</div>
			
			<form action="__SELF__" method="post" class="form-horizontal">
			<div class="indexList">
				<div class="IndexList">				<!--yxf 20171107 判断空页面更改状态内容 S-->							<if condition="$collectList"> 				
					<ul class="like block">
					<volist name="collectList" id="v">
						<li>
							<img src="__IMG__/images/bianj_03.png" class="bianj1"/>
							<input type="checkbox" name="ids[]" value="{$v.id}" style="display: none;" />
							<div class="per">
								<a href="javascript:;" class="f-fl detail"><img src="__ROOT__{$v.logo|getimg=###}"/></a>
								<div class="f-fl">
									<h1>
										<a href="__MODULE__/UserMember/userDetail/uid/{$v.c_uid}/teaching/{$Think.get.teaching}">{$v.nickname}</a><img src="__IMG__/images/
											<switch name='v.sex'>
												<case value='1'>nan_03.png</case>
												<case value='2'>girl_03.png</case>
											</switch>
										"/><span>{$v.minsalary}元/小时</span>
									</h1>
									<p class="moren"><img src="__IMG__/images/idxe_18.jpg"/>
										<switch name="Think.get.teaching">
											<case value="1">想学</case>
											<case value="2">授课</case>
										</switch>:
										<volist name="v.courses" id="c">
										{$c}&emsp;
										</volist>
									</p>
									<eq name="Think.get.teaching" value="2"><p><img src="__IMG__/images/idxe_24.jpg"/> 教过: {$v.students}</p></eq>
									<p><img src="__IMG__/images/idxe_27.jpg"/>地址: {$v.area_id|getArea=###}</p>
									<img src="__IMG__/images/idxe_21.jpg"/ class="posi">
								</div>
								<div class="clear"></div>
							</div>
						
						</li>
					</volist>
					</ul>									<else />									<div class="con_empty  marg">看上哪个</div>					<div class="con_empty">就把ta加入到这里吧</div>								</if>					<!--yxf 20171107 判断空页面更改状态内容 E-->				
					<input type="submit" id="btn" name=""  value="删除" class="ajax-post" target-form="form-horizontal" style="display: none;" />
				</div>
			</div>
			</form>
		</div>
<script>
	$(function(){
		var medi=true;
		var medi1='';
		$('#MyCare header .sure').click(function(){
			if(medi){
				$('.per').css('transform','translateX(30px)');
				$('.bianj1').show(300).attr('src','__IMG__/images/bianj_03.png');
				$('#MyCare header .sure').text('取消');
				$('#btn').slideDown('300');
				medi1=medi;
				$('.f-fl').unbind('click');
			}else{
				$('.per').css('transform','translateX(0px)');
				$('.bianj1').hide(300).attr('src','__IMG__/images/bianj_03.png');
				$('#MyCare header .sure').text('编辑');
				$('#btn').slideUp('300');
				$('.f-fl').bind('click',function(){
					location.href = $('.f-fl h1 a').attr('href');
				});
			}
			medi=!medi;
		});
		$('#MyCare .IndexList li').click(function(){
					if(medi1){
						$(this).css('background','#faf8f8');
						$(this).find('.bianj1').attr('src','__IMG__/images/bianj_06.png').next('input').attr('checked',true);
					}else{
						$(this).css('background','#fff');
						$(this).find('.bianj1').attr('src','__IMG__/images/bianj_03.png').next('input').removeAttr('checked');
					}
					medi1=!medi1;
		});
		$('.f-fl').click(function(){
         
		  location.href = $(this).parent().find('.f-fl').last().find('h1 a').attr('href');
		})
	});
</script>
</block>